import Vue from 'vue'
import Router from 'vue-router'
import TabbarRouter from '@/components/TabbarRouter'
import Home from '@/components/tabbar/Home'
import Classify from '@/components/tabbar/Classify'
import Hot from '@/components/tabbar/Hot'
import Cart from '@/components/tabbar/Cart'
import My from '@/components/tabbar/My'
import productDetail from '@/components/pages/productDetail'
Vue.use(Router)
export default new Router({
  routes: [
    {
      path: '/',
      name: 'TabbarRouter',
      component: TabbarRouter,
      redirect:'/tabbar/Home',
      children:[
        {
          path: '/tabbar/Home',
          component: Home
        },
        {
          path: '/tabbar/Classify',
          component: Classify
        },
        {
          path: '/tabbar/Hot',
          component: Hot
        },
        {
          path:'/tabbar/Cart',
          component:Cart
        },
        {
          path:'/tabbar/My',
          component:My
        }
      ]
    },
    {
       path: '/pages/productDetail',
       name: 'productDetail',
       component: productDetail,
    }
  ]
}) 